# Maintainer: Giovanni Scafora <giovanni@archlinux.org>

pkgname=barcode
pkgver=0.99
pkgrel=5
pkgdesc="A tool to convert text strings to printed bars"
arch=('loong64' 'x86_64')
url="https://www.gnu.org/software/barcode/"
license=('GPL')
depends=('glibc')
source=("ftp://ftp.gnu.org/gnu/${pkgname}/${pkgname}-${pkgver}.tar.xz")
md5sums=('cdc504ee1020e27fbfeebcb0718de054')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  CFLAGS+=' -fcommon' # https://wiki.gentoo.org/wiki/Gcc_10_porting_notes/fno_common

  ./configure --prefix=/usr

  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  make prefix="${pkgdir}/usr" install
}
